#include "cpu/exec/template-start.h"

#define instr je

/*static void do_execute(){
	DATA_TYPE_S val = op_src->val;
	print_asm("je %x",cpu.eip + 1 + DATA_BYTE + op_src->val);
	if(cpu.eflags.ZF == 1)
	cpu.eip += val;
}*/
//跳转若相等
make_helper(concat(je_i_,SUFFIX)){
	int len = concat(decode_i_,SUFFIX)(eip+1);
	print_asm("je 0x%x", (DATA_TYPE_S)op_src->imm + cpu.eip + len + 1);
	//若ZF=1,则跳转
	if(cpu.eflags.ZF == 1) cpu.eip += (DATA_TYPE_S)op_src->imm;
	return len + 1;
}

//make_instr_helper(i)

#include "cpu/exec/template-end.h"